import http from '@/service/request/index.js'


// 获取所有城市
export function getCityApi(params){
	return http.get('/api/shop/city',params)
}
// 获取地址列表
export function getAddressListApi(params){
	return http.get('/api/shop/address',params)
}
// 添加地址
export function createAddressApi(data){
	return http.post('/api/shop/address',data)
}
// 编辑地址
export function editAddressApi(id,data){
	return http.put(`/api/shop/address/${id}`,data)
}
// 删除地址
export function delAddressApi(id){
	return http.delete(`/api/shop/address/${id}`)
}
// 设置默认地址
export function defAddressApi(id,data){
	return http.post(`/api/shop/setDefault/${id}`,data)
}